import { View, Text, ActivityIndicator } from 'react-native'
import React from 'react'

export default function XzLoadMore(props) {
  function content(){
    if(props.status==='loading'){
        return (
          <View style={{flexDirection:'row',justifyContent:'center'}}>
            <ActivityIndicator color={'#0aa1ed'}/>
            <Text>加载中...</Text>
          </View>
        )
    }else if(props.status==='noMore'){
      return (
        <View>
          <Text style={{textAlign:'center'}}>没有更多数据了</Text>
        </View>
      )
    }else{
      return (
        <View>
          <Text style={{textAlign:'center'}}>上拉加载更多</Text>
        </View>
      )
    }
  }
  return (
    <View>
      {content()}
    </View>
  )
}